package com.qing.concurrent.chapter01;

public class TryConcurrency {
    public static void main(String[] args) throws InterruptedException {
        browseNews();
        enjoyMusic();
    }

    private static void browseNews() throws InterruptedException {
        for (;;){
            System.out.println("Uh-huh,the good news");
            Thread.sleep(1);
        }
    }

    private static void enjoyMusic() throws InterruptedException {
        for (;;){
            System.out.println("Uh-huh,the nice music");
            Thread.sleep(1);
        }
    }
}
